<template>
  <section class="main">
    <post-item v-for="item in 20" :key="item"></post-item>
  </section>
</template>

<script setup>
import { onMounted } from "vue";
import { useRoute } from "vue-router";
import request from "../../utils/request";
import PostItem from "./components/PostItem.vue";
onMounted(() => {
  let key = useRoute().params.key;
  request(
    `https://mockapi.eolink.com/SHQdMWnc0600b265c0d20410ed7c36e0eec1dc8fe7e5087/post/search?responseId=1202645&key=${key}`,
    {},
    0
  ).then((res) => {
    console.log(res);
  });
});
</script>
<style scoped lang='less'>
</style>